package com.max.xihu.patterns.responsible.validator;

import java.util.Map;

/**
 * @Author: Max
 * @Date: 2020-09-20 14:54
 * @Description:数据校验器
 */
public class DataValidator extends BaseValidator {

    private Object data;//存在的数据

    public DataValidator(Object object){
        this.data = object;
    }

    @Override
    public boolean check(Map<String, Object> form) {
        Object object = form.get("formData");//提交的数据
        //数据校验逻辑
        return checkNext(form);
    }
}
